<div id="view-content">
    <div class="row-fluid">
        <a href="<?= $this->url(array(), 'users-add'); ?>" class="btn btn-success"><i class="icon-white icon-plus-sign"></i> Add New Client</a>
        <table class="table well">
            <thead>
                <tr>
                    <th class="span1">#</th>
                    <th class="span2">Name</th>
                    <th class="span2">Email</th>
                    <th class="span3">Details</th>
                    <th class="span2">Profile Link</th>                    
                    <th class="span1">User Type</th>
                    <th class="span1"></th>
                </tr>
            </thead>
            <tbody>
                <?php
                $index = 1;
                foreach ($this->fetchAll as $user) {
                    ?>
                    <tr>
                        <th><?= $index ?></th>
                        <td><?= $user['name'] ?></td>
                        <td><?= $user['email'] ?></td>
                        <td><?= $user['details'] ?></td>
                        <td><a target="_blank" href="<?= $user['profileUrl'] ?>" class="btn btn-small btn-info"><i class="icon-white icon-tag"></i> </a></td>                        
                        <td><?= $user['user_type'] ?></td>
                        <td><a class="btn btn-small btn-info" href="<?= $this->url(array('id' => $user['id']), 'users-edit'); ?>"><i class="icon-white icon-edit"></i></a></td>
                    </tr>
                    <?php
                    $index++;
                }
                ?>
            </tbody>
        </table>
    </div>
</div>